<template>
  <div class="card-panel">
    <el-row :gutter="40" class="panel-group">
      <el-col span="6" class="card-panel-col">
        <div class="card-panel">
          <div class="card-panel-icon-wrapper icon-people">
            <img :src="images.employee" />
          </div>
          <div class="card-panel-description">
            <div class="card-panel-text">{{numbers.employee}} 人</div>
          </div>
        </div>
      </el-col>
      <el-col span="6" class="card-panel-col">
        <div class="card-panel">
          <div class="card-panel-icon-wrapper icon-people">
            <img :src="images.loan" />
          </div>
          <div class="card-panel-description">
            <div class="card-panel-text">{{numbers.loan}} 人</div>
          </div>
        </div>
      </el-col>
      <el-col span="6" class="card-panel-col">
        <div class="card-panel">
          <div class="card-panel-icon-wrapper icon-people">
            <img :src="images.deposit" />
          </div>
          <div class="card-panel-description">
            <div class="card-panel-text">{{numbers.deposit}} 人</div>
          </div>
        </div>
      </el-col>
      <el-col span="6" class="card-panel-col">
        <div class="card-panel">
          <div class="card-panel-icon-wrapper icon-people">
            <img :src="images.transfer" />
          </div>
          <div class="card-panel-description">
            <div class="card-panel-text">{{numbers.transfer}} 人</div>
          </div>
        </div>
      </el-col>
    </el-row>
  </div>
</template>

<script>
export default {
  data() {
    return {
      images: {
        employee: require("@/assets/images/员工.png"),
        loan: require("@/assets/images/个人贷款.png"),
        deposit: require("@/assets/images/存款.png"),
        transfer: require("@/assets/images/转账.png"),
      },
      numbers: {
        employee: 6,
        loan: 33,
        deposit: 54,
        transfer: 13,
      }
    };
  },
};
</script>

<style lang="scss" scoped>
.panel-group {
  margin-top: 18px;

  .card-panel-col {
    margin-bottom: 32px;
  }

  .card-panel {
    height: 108px;
    cursor: pointer;
    font-size: 12px;
    position: relative;
    overflow: hidden;
    color: #666;
    background: #fff;
    box-shadow: 4px 4px 40px rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.05);
    height: 124px;
    background: #ffffff;
    border-radius: 10px;
    img {
      width: 60px;
      height: 60px;
      display: inline-block;
    }
    .icon-people {
      color: #40c9c6;
    }

    .icon-message {
      color: #36a3f7;
    }

    .icon-money {
      color: #f4516c;
    }

    .icon-shopping {
      color: #34bfa3;
    }

    .card-panel-icon-wrapper {
      float: left;
      margin: 14px 0 0 14px;
      padding: 16px;
      transition: all 0.38s ease-out;
      border-radius: 6px;
    }

    .card-panel-icon {
      float: left;
      font-size: 48px;
    }

    .card-panel-description {
      float: right;
      font-weight: bold;
      margin: 26px;
      margin-left: 0px;

      .card-panel-text {
        line-height: 18px;
        color: rgba(0, 0, 0, 0.45);
        font-size: 16px;
        margin-bottom: 12px;
      }

      .card-panel-num {
        font-size: 20px;
      }
    }
  }
}
</style>